home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d18
/
qwik30.arc
/
CURSOR.INC
< prev
next >
Wrap
Text File
|
1991-01-09
|
3KB
|
62 lines
{ Cursor.inc - GotoRC,CursorChange,CursorOff,CursorOn ver 3.0, 08-31-87 }
{ GotoRC - move cursor ver 1.3, 11-10-86 }
procedure GotoRC (Row,Col: byte);
begin
Inline( {Assembly by Inline 08/17/87 12:10}
$B4/$02/ { mov ah,$02 ;Set AH = $02}
$31/$DB/ { xor bx,bx ;Set BX=0}
$8E/$C3/ { mov es,bx ;Set ES=0}
$26/ { es: ;Segment override}
$8A/$3E/$62/$04/ { mov bh,[$0462] ;Set BH=current page}
$8A/$76/<ROW/ { mov dh,[bp+<Row] ;Move Row}
$FE/$CE/ { dec dh ;Convert to 0-?? range}
$8A/$56/<COL/ { mov dl,[bp+<Col] ;Move Col}
$FE/$CA/ { dec dl ;Convert to 0-?? range}
$CD/$10); { int $10 ;Set cursor position}
end;
{ CursorChange - changes type or hides cursor, saves old ver 1.3, 11-10-86 }
procedure CursorChange (New: integer; VAR Old: integer);
begin
Inline( {Assembly by Inline 08/17/87 12:10}
$31/$C0/ { xor ax,ax ;Set AX=0}
$8E/$C0/ { mov es,ax ;Set ES=0}
$26/ { es: ;Segment override}
$A1/$60/$04/ { mov ax,wo[$0460] ;Read old cursor mode}
$C4/$7E/<OLD/ { les di,[bp+<Old] ;Set address for Old}
$AB/ { stosw ;Store old value}
$B4/$01/ { mov ah,$01 ;}
$8B/$4E/<NEW/ { mov cx,[bp+<New] ;Get New value}
$CD/$10); { int $10 ;Set cursor change}
end;
{ CursorOff - turns cursor off ver 3.0, 08-31-87 }
procedure CursorOff;
begin
Inline( {Assembly by Inline 08/17/87 12:10}
$31/$C0/ { xor ax,ax ;Set AX=0}
$8E/$C0/ { mov es,ax ;Set ES=0}
$26/ { es: ;Segment override}
$A1/$60/$04/ { mov ax,wo[$0460] ;Read old cursor mode}
$80/$E4/$BF/ { and ah,$BF ;Clear blink bit}
$80/$CC/$20/ { or ah,$20 ;Set hide bit}
$89/$C1/ { mov cx,ax ;Move mode}
$B4/$01/ { mov ah,$01 ;Set function = $01}
$CD/$10); { int $10 ;Set cursor change}
end;
{ CursorOn - turns cursor on ver 3.0, 08-31-87 }
procedure CursorOn;
begin
Inline( {Assembly by Inline 08/17/87 12:10}
$31/$C0/ { xor ax,ax ;Set AX=0}
$8E/$C0/ { mov es,ax ;Set ES=0}
$26/ { es: ;Segment override}
$A1/$60/$04/ { mov ax,wo[$0460] ;Read old cursor mode}
$80/$E4/$DF/ { and ah,$DF ;Clear hide bit}
$89/$C1/ { mov cx,ax ;Move mode}
$B4/$01/ { mov ah,$01 ;Set function = $01}
$CD/$10); { int $10 ;Set cursor change}
end;